package com.idp.common.base;

/**
 * 业务异常
 * @author xubinren
 * @date 2017/3/13 0013
 */
public class BusinessException extends RuntimeException{

	private int errorCode;

	public BusinessException() {
		super();
	}
	
	/**
	 * @param errorCode 错误代码
	 * @param message 信息
	 */
	public BusinessException(int errorCode, String message){
		super(message);
		this.errorCode = errorCode;
	}

	/**
	 * @param message 信息
	 * @param cause cause
	 */
	public BusinessException(String message, Throwable cause) {
		super(message, cause);
	}

	/**
	 * @param message 信息
	 */
	public BusinessException(String message) {
		super(message);
	}

	/**
	 * @param cause cause
	 */
	public BusinessException(Throwable cause) {
		super(cause);
	}

	/**
	 * @since 1.0
	 * @return
	 */
	public int getErrorCode() {
		return errorCode;
	}
	
}
